﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data;
using Help_Us.DataSet.DataSetTableAdapters;

namespace Help_Us.DataAccess
{
    public class SolucionadoresControle
    {
        usuResolvedorSetsTableAdapter objUserResolvedor;
        public SolucionadoresControle()
        {
            objUserResolvedor = new usuResolvedorSetsTableAdapter();
        }

        public void CadastraUsuarioResolvedor(String nome, String sobrenome, String senha, String email, String telResidencial, String telCelular)
        {
            //email, nome, senha, sobrenome, telResidencial, telCelular
            objUserResolvedor.InsertUser(email, nome, senha, sobrenome, telResidencial, telCelular);
        }

        public bool VerificaEmail(String emailUsuario)
        {
            Help_Us.DataSet.DataSet.usuResolvedorSetsDataTable data = objUserResolvedor.buscaEmail(emailUsuario);
            if (data.Rows.Count == 0)
            {
                return true;
            }
            else return false;
        }
    }
}